<?php
require_once 'includes/functions.php';

// Handle routing
$route = $_GET['route'] ?? 'home';

switch ($route) {
    case 'about':
        render_template('about');
        break;
        
    case 'post':
        if (empty($_GET['file'])) {
            header('Location: /');
            exit;
        }
        render_template('post');
        break;
        
    case 'home':
    default:
        render_template('home');
        break;
}
